package com.uniplaza.app.volley;

import com.android.volley.Request;

/**
 * Created by Kim on 2017/1/11.
 * 网络请求 常量
 */

public class ApiConstant {


    /**
     * 测试表示 当为测试时 为 true
     */
    public static final boolean APP_DBG = true;

    /**
     * 内网测试服务器     http://beta.qtl.com/
     * 外网测试服务器     https://qiantuoluorest.quna1788.com/
     */
    private static final String IP_TEST = "http://beta.qtl.com/";
    /**
     * 服务器ip
     */
    private static final String IP_SERVER = "http://dev.qiantuoluo.com:5928/";

    static String IP() {
        return APP_DBG ? IP_TEST : IP_SERVER;
    }

    public static int INVITE_FLAG = 0;//邀请友盟统计map
    public static final String WEIXIN_APICODE = "wxde509ece4927f3cd";//微信appid
    public static final String PAGE_SIZE = "20";//每个页面
    /**
     * 网络请求类型
     */
    public static final int GET = Request.Method.GET;
    public static final int POST = Request.Method.POST;
    public static final int PUT = Request.Method.PUT;
    public static final int DELETE = Request.Method.DELETE;

    /**
     * 网络请求 传参数 key 常量
     * http://d9.mayapi.com/v1/users?page=1&per-page=10
     */
    public static final class KEY {
        public static final String URL_ID = "{id}";                     // 接口请求 ｛id｝ 替换字段
        public static final String ID = "id";                     //
        public static final String OS = "OS";                     // 系统
        public static final String SCREENWIDTH = "SCREENWIDTH";  // 屏幕宽度

        public static final String SECRET = "SECRET";
        public static final String PAGE = "page";                 // 页数
        public static final String PAGESIZE = "pageSize";         // 每页显示数量
        public static final String AUTHORIZATION = "AUTHORIZATION";
    }

    /**
     * 网络请求 URL 常量
     */
    public static class URL {
        public static final String AUTH_CODE = "authcode";          //发送验证码

    }

}
